package com.mnt.gui.base.buildfactory.cellhandle;

import javafx.event.Event;

/**
 * table column to text-field execute event
 * @author 2014-3-29  mnt.cico
 *
 * @param <E> is event type
 * @param <R> row value type
 * @param <V> filed value type
 */
public abstract class EventExecutorAndNewValueHandle<E extends Event, R, V>
{

	/**
	 * event trigger execute this function
	 * 2014-3-29 mnt.cico
	 */
	public abstract void execute(E event, R rowValue, V oldValue, String newValue) throws Exception;
	
	/**
	 * execute error on exception execute this function
	 * 2014-3-29 mnt.cico
	 */
	public void onFailed(Exception e) {
		e.printStackTrace();
	}
}
